package cn.ywsj.ywsjmidtier.controller;

import cn.ywsj.ywsjmidtier.entity.VO.BrandQueryVo;
import cn.ywsj.ywsjmidtier.service.WechatOpenShopApplyFeign;
import cn.ywsj.ywsjmidtier.utils.JsonObjectUtil;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@Api(tags = "开店申请")
@RestController
@RequestMapping("/wechat/openshopapplymgr")
public class WechatOpenShopApplyController {

    @Autowired
    private WechatOpenShopApplyFeign shopApplyFiegn;

    /**
     * 品牌闪购详情1
     * 1
     * @param brandQueryVo
     * @return
     */
    @ApiOperation("品牌闪购详情")
    @PostMapping(value = {"/ajaxopenshop"})
    public String ajaxOpenShop(BrandQueryVo brandQueryVo) {
        return shopApplyFiegn.ajaxOpenShop(JsonObjectUtil.ObjectToJson(brandQueryVo));
    }

    /**
     * 发现推荐列表1
     * 1,10,3
     * @param start
     * @param pageSize
     * @param productLabelSize
     * @return
     */
    @ApiOperation("发现推荐列表")
    @RequestMapping({"/ajaxfindpageproduct"})
    public String findPageProduct(Integer start,Integer pageSize,Integer productLabelSize) {
        return shopApplyFiegn.findPageProduct(start,pageSize,productLabelSize);
    }
    @PostMapping("/getAboutUs")
    public String getAboutUs(Long custId){
        return shopApplyFiegn.getAboutUs(custId);
    }
}
